import request from './request.js';

export default{
    //获取建议列表
    
    getRole(query){
        return request({
            url: BASE+'/wx/getRole',
            method: 'get',
            params:query
        }) 
    },
    getOn(query){
        return request({
            url: BASE+'/wx/getPermission',
            method: 'get',
            data:query,
            params:query
        }) 
    },
    getOpenID(query){
        return request({
            url: BASE+'/wx/getOpenIdBaseInfoByCode',
            method: 'get',
            params:query
        })
    },
    addRemark(query){
        return request({
            url:`http://47.99.44.146:6534/addRemark`,
            method: 'post',
            data:query
        })
    },
    getInfo(query){
        return request({
            url: BASE+`/publicUser/info/${openid}`,
            method: 'get'
        })
    },
    update(query){
        return request({
            url: BASE+'/publicUser/update',
            method: 'put',
            data:query
        })
    },
    
    add(query){
        return request({
            url: BASE+'/publicUser/save',
            method: 'post',
            data:query
        })
    },
    getVillage(query){
        return request({
            url: BASE+'/community/queryAllCommunity',
            method: 'post'
        })
    }
}